<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"+"user/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
      <base href="<%=basePath%>">
    
	  <title>账户设置</title>
	  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	  <meta name="keywords" content="fly,layui,前端社区">
	  <meta name="description" content="Fly社区是模块化前端UI框架Layui的官网社区，致力于为web开发提供强劲动力">
	  <link rel="stylesheet" href="../res/layui/css/layui.css">
	  <link rel="stylesheet" href="../res/css/global.css">
	  <script src="../res/layui/layui.js"></script>
  </head>
<body>

<!-- <div class="header">
  <div class="main">
    <a class="logo" href="../post/index.html" title="网博">网博社区</a>
    <div class="nav">
      <a class="nav-this" href="../post/index.html">
        <i class="iconfont icon-wenda"></i>问答
      </a>
    </div>
    
    <div class="nav-user">      
      登入后的状态
      
      <a class="avatar" href="home.html">
        <img src="../res/images/avatar/11.jpg">
        <cite>贤心</cite>
        <i>VIP</i>
      </a>
      <div class="nav">
        <a href="set.html"><i class="iconfont icon-shezhi"></i>设置</a>
        <a href="login.html"><i class="iconfont icon-tuichu" style="top: 0; font-size: 22px;"></i>退了</a>
      </div>
    </div>
  </div>
</div> -->


	<div class="main fly-user-main layui-clear">
		<ul class="layui-nav layui-nav-tree layui-inline" lay-filter="user">
			<li class="layui-nav-item"><a href="showUserHome2"> <i
					class="layui-icon">&#xe609;</i> 我的主页 </a></li>
			<li class="layui-nav-item "><a href="showIndexUser?userId=${User.userId }"> <i
					class="layui-icon">&#xe612;</i> 用户中心 </a></li>
			<li class="layui-nav-item layui-this"><a href="user/set.jsp"> <i
					class="layui-icon">&#xe620;</i> 基本设置 </a></li>
			<li class="layui-nav-item"><a href="showMessage?userId=${User.userId }"> <i
					class="layui-icon">&#xe611;</i> 我的消息 </a></li>
			<li class="layui-nav-item  "><a href="showVip?userId=${User.userId }"> <i
					class="layui-icon">&#xe61a;</i> 账户充值/会员 </a></li>
				<li class="layui-nav-item"><a href="showReport"> <i
					class="layui-icon">&#xe61a;</i> 审核举报 </a></li>
		</ul>
  
  <div class="site-tree-mobile layui-hide">
    <i class="layui-icon">&#xe602;</i>
  </div>
  <div class="site-mobile-shade"></div>
  
  <div class="fly-panel fly-panel-user" pad20>
    <div class="layui-tab layui-tab-brief" lay-filter="user">
      <ul class="layui-tab-title" id="LAY_mine">
        <li class="layui-this" lay-id="info">我的资料</li>
        <li lay-id="avatar">头像</li>
        <li lay-id="pass">密码</li>
      </ul>
      <div class="layui-tab-content" style="padding: 20px 0;">
        <div class="layui-form layui-form-pane layui-tab-item layui-show">
          <!-- 表单 -->
          <form action="updateUserDetail" method="post">
            <div class="layui-form-item">
              <label for="L_email" class="layui-form-label">邮箱</label>
              <div class="layui-input-inline">
                <input type="text"  required lay-verify="email" class="layui-input" value="${User.userEmail }" name="userEmail">
              </div></div>
            <div class="layui-form-item">
              <label for="L_username" class="layui-form-label">昵称</label>
              <div class="layui-input-inline">
                <input type="text" required lay-verify="required" class="layui-input" value="${User.userName }" name="userName">
              </div>
              <div class="layui-inline">
                <div class="layui-input-inline">
                  <input type="radio" value="${User.userSex }" name="userSex" checked title="${User.userSex }">
                  <c:if test="${User.userSex == '男' }">
                  	<input type="radio" value="女" name="userSex" title="女">
                  	<!-- <input type="radio" value="女" name="userSex" title="女"> -->
                  </c:if>
                  <c:if test="${User.userSex == '女' }">
                  	<!-- <input type="radio" value="男" name="userSex" checked title="男"> -->
                  	<input type="radio" value="男" name="userSex" title="男">
                  </c:if>
                </div>
              </div>
            </div>
            <div class="layui-form-item">
								<label for="L_email" class="layui-form-label">银行卡</label>
								<div class="layui-input-inline">
										<input type="text" class="layui-input" value="${bankCard.bankCardNumber }">
								</div>
			</div>
            
            <div class="layui-form-item">
              <label for="L_city" class="layui-form-label">城市</label>
              <div class="layui-input-inline">
                <input type="text" class="layui-input" placeholder="未填写" value="${User.userCity }" name="userCity">
              </div>
            </div>
            <div class="layui-form-item layui-form-text">
              <label for="L_sign" class="layui-form-label">签名</label>
              <div class="layui-input-block">
                <textarea placeholder="随便写些什么刷下存在感~"  autocomplete="off" class="layui-textarea" style="height: 80px;" name="userMotto">${User.userMotto }</textarea>
              </div>
            </div>
            <div class="layui-form-item">
              <input class="layui-btn"  value="确认修改" type="submit" />
            </div>
            </form>
          </div>
          
          <div class="layui-form layui-form-pane layui-tab-item">
            <div class="layui-form-item">
              <div class="avatar-add">
                <p>建议尺寸168*168，支持jpg、png、gif，最大不能超过30KB</p>
                <div class="upload-img">
                  <input type="file" name="file" id="LAY-file" lay-title="上传头像">
                </div>
                <img src="../res/images/avatar/3.jpg">
                <span class="loading"></span>
              </div>
            </div>
          </div>
          
          <div class="layui-form layui-form-pane layui-tab-item">
            <!-- 修改密码表单 -->
            <form action="updatePwd" method="post">
              <div class="layui-form-item">
                <label for="L_nowpass" class="layui-form-label">当前密码</label>
                <div class="layui-input-inline">
                  <input type="password"  required lay-verify="required" autocomplete="off" class="layui-input" name="oldPwd">
                </div>
              </div>
              <div class="layui-form-item">
                <label for="L_pass" class="layui-form-label">新密码</label>
                <div class="layui-input-inline">
                  <input type="password"  required lay-verify="required" autocomplete="off" class="layui-input" name="newPwd">
                </div>
                <div class="layui-form-mid layui-word-aux">6到16个字符</div>
              </div>
              <div class="layui-form-item">
                <label for="L_repass" class="layui-form-label">确认密码</label>
                <div class="layui-input-inline">
                  <input type="password"  required lay-verify="required" autocomplete="off" class="layui-input" name="confirmPwd">
                </div>
              </div>
              <div class="layui-form-item">
                <input class="layui-btn"  value="确认修改" type="submit">
              </div>
              <!-- 错误提示 -->
              <div class="checkbox mg-b25">
				<label>
					<c:if test="${UPDATE_PWD_MSG == null }">
						提示：<span class="login_msg" style="color: black">修改密码成功后，需要重新登录。</span>
					</c:if>
					<c:if test="${UPDATE_PWD_MSG != null }">
						提示：<span class="login_msg" style="color: red">${UPDATE_PWD_MSG }</span>
					</c:if>
				</label>
			  </div>
            </form>
          </div>
        </div>
      </div>
    </div>
  </div>

	<!-- <div class="footer">
  <p><a href="#">网博社区</a> 2017 &copy; <a href="#/">njwangbo.com</a></p>
  <p>
    <a href="#" target="_blank">产品授权</a>
    <a href="#" target="_blank">网博社区</a>
    <a href="#" target="_blank">微信公众号</a>
  </p>
</div> -->

<script>
		layui.use('element', function() {
			var element = layui.element();
		});
	</script>
<script>

layui.cache.page = '';
layui.cache.user = {
  username: '游客'
  ,uid: -1
  ,avatar: '../res/images/avatar/00.jpg'
  ,experience: 83
  ,sex: '男'
};
layui.config({
  version: "2.0.0"
  ,base: '../res/mods/'
}).extend({
  fly: 'index'
}).use('fly');
</script>

</body>
</html>
